/*
 * File Name : node.cpp
 * Auther : dream.liuguobiao
 * Create Date : 2010-5-6
 * Last Edit : 2010-5-6
 */


#ifndef NODE_H
#define NODE_H

#include <string>

class node {
private:
  std::string name;
  std::string path;
  //float size;
  node *brother;
  node *father;
  int mod;
  int userID;
  int groupID;

public:
  node();
  virtual ~node(){};

  std::string *get_name();
  std::string *get_path();
  bool set_name( std::string *new_name );
  node *get_brother();
  bool set_brother( node *new_brother );
  node *get_father();
  bool set_father( node *new_father );
  int get_mod();
  bool set_mod( int new_mod );
  int get_userID(){return userID;}
  bool set_userID( int new_userID){ userID = new_userID;return true;}
  int get_groupID(){return groupID;}

  virtual int get_type() = 0;
  virtual float get_size() = 0;
  virtual node *get_son() = 0 ;
  virtual bool set_son( node *new_son ) = 0 ;
  virtual std::string *get_data() = 0 ;
  virtual bool set_data( std::string *new_data ) = 0 ;
};

#endif
